package com.aiyige.utils;

import android.text.TextUtils;

import com.aiyige.city.model.City;
import com.aiyige.city.util.CityUtil;
import com.aiyige.page.edituserinfo.model.Province;
import com.aiyige.page.publish.guarantee.model.GuaranteeItem;
import com.aiyige.page.selectregion.model.RegionItem;
import com.aiyige.utils.banner.BannerAdapter;

import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Random;

/**
 * Created by zhuyakun on 2017/10/18.
 */

public class DummyDataUtil {
    private static Random random = new Random();
    private static String[] imageUrlArray = {"https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1942924814,1813408375&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=3660918644,2477633320&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3002450272,3513177793&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2257366377,1526496951&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2999613097,1574427479&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=1700425989,3002751876&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=200870097,3556080697&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=4022801752,1147505013&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2131205662,1725422972&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1149868338,1786541942&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=3342915631,1994612319&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=3510992391,970315798&fm=200&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1648086401,180994876&fm=27&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2503452539,934841133&fm=200&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=2305119518,3349332113&fm=27&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2251410992,1013162754&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=4074655655,3913363897&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=2229787173,1529798636&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2112922452,1025940732&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=331406502,1564449579&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=1679707090,2268156548&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=335081894,2281243220&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3562478719,2326707112&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=3556193862,2051987174&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1648086401,180994876&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3246905112,3495547847&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=3844233833,3942617167&fm=200&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=975878983,2392470128&fm=11&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2577940881,313139597&fm=11&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=3342915631,1994612319&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=2722599398,3431377071&fm=200&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1891003518,813611907&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1615575634,4119176251&fm=11&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=2305119518,3349332113&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2112922452,1025940732&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3648105010,4011372685&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=1818374468,1246331283&fm=11&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=276813578,2219466530&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2898000197,2458188371&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=2229787173,1529798636&fm=27&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1407465561,2169083741&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=4074655655,3913363897&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=2962373790,3665837229&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=1813657935,350822498&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=3048842458,335994888&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=235095027,63531469&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=91531861,524826040&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=2478348785,905143055&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2002029010,737571602&fm=200&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2324991341,964547337&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=3990209058,403613144&fm=200&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=782526298,288442001&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=3965895917,3845310417&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1407777833,57080156&fm=11&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1630125939,4135682140&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=896658315,2502251420&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=816863604,4119850766&fm=11&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=2467353589,2277698833&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=3990698668,1841691786&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1515757717,1279718124&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=646265142,702968958&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1682467566,3859536673&fm=11&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=2799343949,1874971378&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=2418226610,2868081468&fm=27&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2656753429,2377375727&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=2888635565,3576638811&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=192694685,2911994758&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=3683327986,1317294329&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=1979818350,418577826&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1903284583,2406455080&fm=11&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=2864750697,2853617986&fm=11&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=2677410098,3213791631&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=2409248017,3559038252&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=2260623150,3706222085&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=474859922,2901243381&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=704786987,3252872323&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=2818660063,53944668&fm=200&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3043732628,1477417083&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=4032300341,2620734131&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=108850543,2414376645&fm=27&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=3557264286,851602452&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=2754269779,2694862479&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=547226397,2177587365&fm=27&gp=0.jpg",
            "https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=2101120543,1186445131&fm=11&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=1255639529,2457917231&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=1031839371,3542952383&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=1775808145,4150969167&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1871519940,654460375&fm=11&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=724036384,2667162972&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFuXSh_Q1YnxGkpoWK1HF6hhy/it/u=553096057,1885451854&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1855341408,172864417&fm=200&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=2078072412,47718508&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=2500204920,1921492723&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFuHSh_Q1YnxGkpoWK1HF6hhy/it/u=2476672446,1402507558&fm=27&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=4122749615,3254682254&fm=27&gp=0.jpg",
            "https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=1842004509,3701356190&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=3187801856,2663441372&fm=27&gp=0.jpg",
            "https://ss0.bdstatic.com/70cFvHSh_Q1YnxGkpoWK1HF6hhy/it/u=3176804069,3652195907&fm=11&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=3379587492,2193729223&fm=11&gp=0.jpg",
            "https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=3204975662,3065541419&fm=200&gp=0.jpg"};
    private static String[] userNameArray = {"张力弘",
            "张雨卓",
            "张广",
            "张天合",
            "张天弘",
            "张岩",
            "张春军",
            "张润兵",
            "张铭峰",
            "张洛嘉",
            "张弘力",
            "张汉涛",
            "张广嘉",
            "张荐成",
            "张广森",
            "张荐程",
            "张强",
            "张如",
            "张峰铭",
            "张志男",
            "张键程",
            "张健程",
            "张学汉",
            "张清洋",
            "张才铭",
            "张永红",
            "张铱",
            "张云",
            "张博涛",
            "张连喜",
            "张庆",
            "张雷",
            "张金华",
            "张景智",
            "张德勤",
            "张飞",
            "张致墚",
            "张顺娃",
            "张智墚",
            "张忠泽",
            "张先智",
            "张役军",
            "张红东",
            "张为为",
            "张红兵",
            "张瀚为",
            "张睿扬",
            "张瀚文",
            "张扬",
            "张毅",
            "张政",
            "张岱",
            "张晗",
            "张靖",
            "张艺扬",
            "张亚",
            "张路",
            "张立记",
            "张志豪",
            "张劲旭",
            "张浩",
            "张志林",
            "张太权",
            "张宏理",
            "张祺康",
            "张永和",
            "张荣淦",
            "张世杰",
            "张世国",
            "张晓林",
            "张世翔",
            "张勇",
            "张晓霖",
            "张誉竞",
            "张灏",
            "张效磊",
            "张宙獯",
            "张子轩",
            "张林",
            "张戈",
            "张子宣",
            "张紫轩",
            "张建科",
            "张洪",
            "张健科",
            "张立平",
            "张一凡",
            "张旭东",
            "张异域",
            "张坤",
            "张新辉",
            "张雪域",
            "张雪峰",
            "张润东",
            "张鹏云",
            "张一勤",
            "张鹏",
            "张殿超",
            "张敬林",
            "张峥",
            "张健华",
            "张一磊",
            "张新明",
            "张丙军",
            "张士明",
            "张康宁",
            "张春",
            "张立昌",
            "张亮",
            "张来有",
            "张耘文",
            "张津颦",
            "张挥苑",
            "张怀溪",
            "张怀文",
            "张怀颦",
            "张道乾",
            "张霍文",
            "张溥",
            "张家瑞",
            "张志平",
            "张克强",
            "张洪强",
            "张奎华",
            "张奎举",
            "张炳峰",
            "张超",
            "张永豪",
            "张纪文",
            "张又杰",
            "张建生",
            "张灿灿",
            "张洪钰",
            "张西伦",
            "张洪博",
            "张奎璇",
            "张红波",
            "张烜辅",
            "张红博",
            "张庆红",
            "张金波",
            "张昕",
            "张弘毅",
            "张益杰",
            "张云鹏",
            "张宝钦",
            "张亦然",
            "张奎璧",
            "张晓钟",
            "张加旭",
            "张航",
            "张平",
            "张佳旭",
            "张家旭",
            "张文迪",
            "张涵之",
            "张家铭",
            "张旭",
            "张涵王",
            "张奕轩",
            "张劲松",
            "张承",
            "张培培",
            "张义澎",
            "张君",
            "张亦澎",
            "张以澎",
            "张艺轩",
            "张景桉",
            "张哲",
            "张可",
            "张潋铭",
            "张华生",
            "张天贵",
            "张利锋",
            "张嘉恩",
            "张天云",
            "张德育",
            "张逸轩",
            "张亦轩",
            "张然",
            "张德焱",
            "张子超",
            "张烨",
            "张睿麟",
            "张诗煜",
            "张豪生",
            "张传俭",
            "张克",
            "张成刚",
            "张书煜",
            "张天迈",
            "张小宁",
            "张永金",
            "张策",
            "张立红",
            "张建厂",
            "张晓荣",
            "张皓怡",
            "张邃",
            "张天译",
            "张连新",
            "张光复",
            "张天和",
            "张天河",
            "张天",
            "张唐",
            "张天鹏",
            "张山",
            "张德辉",
            "张洋",
            "张发玉",
            "张澜献",
            "张心煜",
            "张中天",
            "张春武",
            "张庭",
            "张程睿",
            "张守功",
            "张宇",
            "张腾远",
            "张喜",
            "张雨生",
            "张灏檬",
            "张邴尧",
            "张力沣",
            "张帅军",
            "张卜少",
            "张艺瀚",
            "张骥",
            "张青卫",
            "张德红",
            "张树康",
            "张树广",
            "张琦",
            "张永",
            "张树发",
            "张瀚方",
            "张尧",
            "张树清",
            "张文涛",
            "张竞航",
            "张如意",
            "张树一",
            "张源意",
            "张树搏",
            "张利平",
            "张红池",
            "张波",
            "张懿",
            "张勤",
            "张焱",
            "张熙麟",
            "张珂",
            "张欣武",
            "张思远",
            "张树威",
            "张全梁",
            "张煜涛",
            "张涛",
            "张文勤",
            "张军",
            "张全睿",
            "张万江",
            "张捷",
            "张轲",
            "张海生",
            "张树峰",
            "张万林",
            "张敏江",
            "张藤严",
            "张竣",
            "张鹏超",
            "张德焕",
            "张德灿",
            "张运来",
            "张斌",
            "张旺邑",
            "张润恒",
            "张德颍",
            "张林江",
            "张丛斌",
            "张纪元",
            "张雨轩",
            "张元",
            "张天宝",
            "张程瑞",
            "张嘉荣",
            "张奕",
            "张学震",
            "张昀",
            "张学农",
            "张钰鑫",
            "张云飞",
            "张奕文",
            "张建业",
            "张效云",
            "张永峰",
            "张学雷"};

    public static List<BannerAdapter.Data> generateDummyBannerData() {
        List<BannerAdapter.Data> data = new LinkedList<>();
        for (int i = 0; i < 3; ++i) {
            BannerAdapter.Data bannerAdapterData = new BannerAdapter.Data();
            bannerAdapterData.setId("");
            bannerAdapterData.setTitle("");
            bannerAdapterData.setActivityId(0);
            bannerAdapterData.setUrl("");
            bannerAdapterData.setLink("");
            bannerAdapterData.setRouter("");
            bannerAdapterData.setType(0);
            bannerAdapterData.setOwner("");
            bannerAdapterData.setOrderMe(0);
            bannerAdapterData.setStatus(0);
            bannerAdapterData.setCreateTime(0);
            bannerAdapterData.setUpdateTime("");
            data.add(bannerAdapterData);
        }
        return data;
    }

    public static List<RegionItem> getChinaRegionData() {
        try {
            List<RegionItem> tempRegionItemList = new LinkedList<>();
            List<City> cityList = CityUtil.getCityList();
            for (City city : cityList) {
                RegionItem regionItem = new RegionItem(city.getCity(), city.getProvince() + " " + city.getCity(), city.getCityIndex(), RegionItem.TYPE_DATA, city.getPinyin(), city.getId());
                tempRegionItemList.add(regionItem);
            }
            Collections.sort(tempRegionItemList, new Comparator<RegionItem>() {
                @Override
                public int compare(RegionItem o1, RegionItem o2) {
                    return o1.getPinyin().compareTo(o2.getPinyin());
                }
            });

            List<RegionItem> regionItemList = new LinkedList<>();
            String index = "";
            for (RegionItem regionItem : tempRegionItemList) {
                if (!regionItem.getIndex().equals(index)) {
                    index = regionItem.getIndex();
                    regionItemList.add(new RegionItem("", "", index, RegionItem.TYPE_INDEX, "", ""));
                }
                regionItemList.add(regionItem);
            }
            return regionItemList;
        } catch (Exception e) {
            return new LinkedList<>();
        }
    }


    public static String getCityId(String province, String city) {
        List<City> cityList = CityUtil.getCityList();
        for (City item : cityList) {
            if (province.contains(item.getProvince()) && city.contains(item.getCity())) {
                return item.getId();
            }
        }
        return "";
    }

    public static City getCityById(String id) {
        if (TextUtils.isEmpty(id)) return null;
        List<City> cityList = CityUtil.getCityList();
        for (City city : cityList) {
            if (id.equals(city.getId())) {
                return city;
            }
        }
        return null;
    }


    public static List<Province> getChinaProvince() {
        try {
            List<Province> provinceList = new LinkedList<>();
            Map<String, Province> provinceMap = new HashMap<>();
            List<City> cityList = CityUtil.getCityList();
            for (City city : cityList) {
                if (provinceMap.containsKey(city.getProvince())) {
                    Province province = provinceMap.get(city.getProvince());
                    province.getCity().add(Province.City.newBuilder()
                            .id(city.getId())
                            .name(city.getCity())
                            .shortName(city.getCity())
                            .build());
                } else {
                    Province province = new Province();
                    province.setName(city.getProvince());
                    province.getCity().add(Province.City.newBuilder()
                            .id(city.getId())
                            .name(city.getCity())
                            .shortName(city.getCity())
                            .build());
                    provinceMap.put(city.getProvince(), province);
                }
            }
            provinceList.addAll(provinceMap.values());
            return provinceList;
        } catch (Exception e) {
            return new LinkedList<>();
        }
    }


    public static String getImageUrl() {
        return imageUrlArray[Math.abs(random.nextInt()) % imageUrlArray.length];
    }

    public static String getUserName() {
        return userNameArray[Math.abs(random.nextInt()) % userNameArray.length];
    }


    public static List<GuaranteeItem> generateGuaranteeData() {
        List<GuaranteeItem> guaranteeItemList = new LinkedList<>();
        {
            GuaranteeItem guaranteeTitle = new GuaranteeItem();
            guaranteeTitle.setId("1");
            guaranteeTitle.setTitle("资讯答疑");
            guaranteeTitle.setContent("保证资讯答疑");
            guaranteeItemList.add(guaranteeTitle);
        }
        {
            GuaranteeItem guaranteeTitle = new GuaranteeItem();
            guaranteeTitle.setId("2");
            guaranteeTitle.setTitle("差一补十");

            guaranteeTitle.setContent("保证差一补十");
            guaranteeItemList.add(guaranteeTitle);
        }

        {
            GuaranteeItem guaranteeTitle = new GuaranteeItem();
            guaranteeTitle.setId("3");
            guaranteeTitle.setTitle("复训");
            guaranteeTitle.setContent("保证复训");
            guaranteeItemList.add(guaranteeTitle);
        }
        return guaranteeItemList;
    }
}
